package com.wu.layer.stereotype.simple.controller;

import com.wu.framework.inner.layer.web.EasyController;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

/**
 * @EasyController 测试模版
 */
@Component
public class EasyControllerTest {

    @Api(tags = "注解使用方式简单")
    @EasyController("/easy/test")
    public class EasyControllerAPITest {
        @ApiOperation("注解使用方式简单 运行run")
        @PostMapping("/run")
        public void run(){}

    }



    @Api(tags = "注解使用方式常规")
    @RestController
    @RequestMapping("/normal/test")
    public class NormalControllerAPITest {

        @ApiOperation("注解使用方式常规 运行run")
        @PostMapping("/run")
        public void run(){}

    }

    @Controller
    @ResponseBody
    @Api(tags = "注解使用方式old常规")
    @RequestMapping("/old/test")
    public class NormalOldControllerAPITest {

        @ApiOperation("注解使用方式old常规 运行run")
        @PostMapping("/run")
        public void run(){}

    }
}


